package com.ymttest.database.sqlwapper;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.ymatou.common.lang.CipherUtil;
import com.ymt.core.tool.FormatUtil;
import com.ymt.database.SqlManager;
import com.ymttest.business.service.JUserCallService;
import com.ymttest.database.model.*;
import com.ymttest.utils.YMTDateUtil;
import com.ymttest.utils.DataUtil.Random;

public class FileMd5Wapper {
	SqlManager manage;

	public FileMd5Wapper() {
		manage = new SqlManager("imagemd5");
	}



	/**
	 * 查询微信用户映射 im用 记录uid和微信token关系
	 * 
	 * @param uid
	 * @return
	 */
	public List<Map> selectConfirmFile(String path) {
		Map<String, Object> params = new HashMap<String, Object>();
		params.put("path", path);
		List<Map> m = (List<Map>) manage.getSelectResults("com.ymttest.database.mapping.FileMd5Mapper.selectConfirmFile", params);
		manage.commit();
		return m;
	}
	public List<Map> selectFilemd5(String path) {
		Map<String, Object> params = new HashMap<String, Object>();
		params.put("path", path);
		List<Map> m = (List<Map>) manage.getSelectResults("com.ymttest.database.mapping.FileMd5Mapper.selectFilemd5", params);
		manage.commit();
		return m;
	}
	public List<Map> selectExpiredFile(String path) {
		Map<String, Object> params = new HashMap<String, Object>();
		params.put("path", path);
		List<Map> m = (List<Map>) manage.getSelectResults("com.ymttest.database.mapping.FileMd5Mapper.selectExpiredFile", params);
		manage.commit();
		return m;
	}

	public static void main(String[] args) throws Exception {
		// new JUserWapper().updateLoginId(30163320, "130163320");
		System.out.println(FormatUtil.beanToGSONString(new FileMd5Wapper().selectConfirmFile("http://pic1.ymatou.com/G01/M00/1C/18/rBBlD19v_-qAGQpYAACS051oMTA354.png")));
		// System.out.println(FormatUtil.beanToGSONString(user));
		// List<Userinfoex> userex= new JUserWapper().selectUserinfoexByUid(4);
		// System.out.println(FormatUtil.beanToGSONString(userex));
		// new JUserWapper().removeMoblie(416532);
	}

}
